<template>
	<view class="profile-container">
		<!-- 用户信息区域 -->
		<view class="user-info">
			<view class="avatar">
				<text class="icon">👤</text>
			</view>
			<view class="user-details">
				<text class="username">用户昵称</text>
				<text class="user-level">VIP会员</text>
			</view>
		</view>
		
		<!-- 功能菜单 -->
		<view class="menu-list">
			<view class="menu-item" @click="handleMenuClick('orders')">
				<text class="icon">📋</text>
				<text class="menu-text">我的订单</text>
				<text class="arrow">></text>
			</view>
			<view class="menu-item" @click="handleMenuClick('cart')">
				<text class="icon">🛒</text>
				<text class="menu-text">购物车</text>
				<text class="arrow">></text>
			</view>
			<view class="menu-item" @click="handleMenuClick('favorites')">
				<text class="icon">❤️</text>
				<text class="menu-text">我的收藏</text>
				<text class="arrow">></text>
			</view>
			<view class="menu-item" @click="handleMenuClick('settings')">
				<text class="icon">⚙️</text>
				<text class="menu-text">设置</text>
				<text class="arrow">></text>
			</view>
		</view>
		
		<!-- 底部导航栏 -->
		<view class="bottom-nav">
			<view class="nav-item" @click="navigateTo('/pages/index/index')">
				<text class="icon">🏠</text>
				<text class="nav-text">首页</text>
			</view>
			<view class="nav-item" @click="navigateTo('/pages/menu/menu')">
				<text class="icon">🍸</text>
				<text class="nav-text">点单</text>
			</view>
			<view class="nav-item active" @click="navigateTo('/pages/profile/profile')">
				<text class="icon">👤</text>
				<text class="nav-text">我的</text>
			</view>
		</view>
	</view>
</template>

<script>
	export default {
		data() {
			return {
				
			}
		},
		methods: {
			handleMenuClick(type) {
				uni.showToast({
					title: '功能开发中',
					icon: 'none'
				});
			},
			navigateTo(url) {
				uni.reLaunch({
					url: url
				});
			}
		}
	}
</script>

<style scoped>
.profile-container {
	min-height: 100vh;
	background-color: #f5f5f5;
	padding-bottom: 120rpx;
}

.user-info {
	background-color: #d32f2f;
	padding: 85rpx 40rpx 60rpx 40rpx;
	display: flex;
	align-items: center;
}

.avatar {
	width: 120rpx;
	height: 120rpx;
	background-color: #fff;
	border-radius: 50%;
	display: flex;
	align-items: center;
	justify-content: center;
	margin-right: 40rpx;
}

.avatar .icon {
	font-size: 60rpx;
}

.user-details {
	flex: 1;
}

.username {
	font-size: 36rpx;
	color: #fff;
	font-weight: bold;
	display: block;
	margin-bottom: 10rpx;
}

.user-level {
	font-size: 28rpx;
	color: #ffd700;
	background-color: rgba(255, 255, 255, 0.2);
	padding: 8rpx 20rpx;
	border-radius: 20rpx;
}

.menu-list {
	background-color: #fff;
	margin: 30rpx;
	border-radius: 16rpx;
	overflow: hidden;
}

.menu-item {
	display: flex;
	align-items: center;
	padding: 40rpx;
	border-bottom: 1rpx solid #f0f0f0;
}

.menu-item:last-child {
	border-bottom: none;
}

.menu-item .icon {
	font-size: 40rpx;
	margin-right: 30rpx;
}

.menu-text {
	flex: 1;
	font-size: 32rpx;
	color: #333;
}

.arrow {
	font-size: 32rpx;
	color: #ccc;
}

.bottom-nav {
	position: fixed;
	bottom: 0;
	left: 0;
	right: 0;
	height: 120rpx;
	background-color: #fff;
	border-top: 1rpx solid #eee;
	display: flex;
	align-items: center;
	justify-content: space-around;
	padding-bottom: env(safe-area-inset-bottom);
}

.nav-item {
	display: flex;
	flex-direction: column;
	align-items: center;
	padding: 20rpx;
}

.nav-item .icon {
	font-size: 48rpx;
	color: #666;
	margin-bottom: 8rpx;
}

.nav-item.active .icon {
	color: #d32f2f;
}

.nav-text {
	font-size: 24rpx;
	color: #666;
}

.nav-item.active .nav-text {
	color: #d32f2f;
}
</style> 